package com.medusa.aps.business.modules.modeling.mp.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.medusa.aps.business.model.pagination.Page;
import com.medusa.aps.business.modules.modeling.model.input.WorkingProcedureDTO;
import com.medusa.aps.business.modules.modeling.model.input.WorkingProcedureParam;
import com.medusa.aps.business.modules.modeling.model.output.ProcedureVO;
import com.medusa.aps.business.modules.modeling.model.output.WorkingProcedureVO;
import com.medusa.aps.business.modules.modeling.mp.entity.WorkingProcedure;

import java.util.List;
import java.util.Set;

/**
 * 工序服务接口
 *
 * @author yuxh
 * @since 2023-08-14 17:37:53
 */
public interface WorkingProcedureService extends IService<WorkingProcedure> {

    /**
     * 分页查询工序列表
     *
     * @param page             分页参数
     * @param workingProcedure 查询参数
     * @return 分页数据
     */
    Page<WorkingProcedureVO> selectWorkingProcedurePage(Page<WorkingProcedure> page, WorkingProcedureParam workingProcedure);

    WorkingProcedureVO detail(Integer id);

    /**
     * 新增工序
     *
     * @param workingProcedures ${@link WorkingProcedureDTO}
     */
    void saveWorkingProcedure(List<WorkingProcedureDTO> workingProcedures);

    void updateWorkingProcedure(WorkingProcedureDTO workingProcedure);

    void removeWorkingProcedure(List<Integer> processIds);
    Boolean existsProcessRoute(Integer id);

    List<ProcedureVO> selectWorkingProcedureBatch(Set<Integer> workingProcedureIds);
}

